import VueRouter from 'vue-router'
import SinglePage from '../pages/SinglePage'
import MusicBodySearch from '../pages/MusicBodySearch.vue'
import SongSheet from '../pages/SongSheet.vue'
import PersonalPage from '../pages/PersonalPage'
import User from '../pages/User.vue'
import DetailPlay from '../components/DetailPlay.vue'
import MusicBody from '../components/MusicBody.vue'
import RankingList from '../pages/RankingList.vue'
import SongSheetPage from '../pages/SongSheetPage.vue'
import AlbumPage from '../pages/AlbumPage.vue'
import OptionNav from '../pages/OptionNav.vue'







export default new VueRouter({
    routes: [
        
        
        {
            path: '/discover',
            component: OptionNav,
            children: [
                {
                    path: '',
                    component: MusicBody
                },
                {
                    path: 'toplist',
                    component: RankingList,
                },
                {
                    path: 'playlist',
                    component: SongSheetPage
                },
                    




                
            ]
        },
        {
            path: '',
            component: OptionNav,
            children: [
                {
                    path: '',
                    component: MusicBody
                },
                {
                    path: '/playlist',
                    component: SongSheet,
                },
                {
                    path: '/album',
                    component: AlbumPage,
                },
                {
                    path: '/song',
                    component: SinglePage,
                },
                {
                    path: '/search',
                    component: MusicBodySearch,
                },
            ]
        },




        
        {
            path: '/user',
            component: User,
            children: [
                {
                    path: 'home',
                    component: PersonalPage,

                },
                {
                    path: 'songs',
                    component: DetailPlay,
                }




            ]
        },
        
        



    ],
    scrollBehavior() {
        return { x: 0, y: 0 }
    }
}

)